import request from '@/utils/request'

//  获取商品计量单位分页列表
export function listGoodsUnit(query){
  return request({
    url: '/manager/goods/unit/list',
    method: 'get',
    params: query
  })
}
//  添加商品计量单位
export function addGoodsUnit(data){
  return request({
    url: '/manager/goods/unit',
    method: 'post',
    data: data
  })
}

//  编辑商品计量单位
export function editGoodsUnit(data){
  return request({
    url: '/manager/goods/unit',
    method: 'put',
    data: data
  })
}

// 删除商品计量单位
export function delGoodsUnit(ids) {
  return request({
    url: '/manager/goods/unit/' + ids,
    method: 'delete'
  })
}

// 商品计量单位详情
export function getGoodsUnit(id) {
  return request({
    url: '/manager/goods/unit/get/' + id,
    method: 'get',
  })
}


